Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. The Weird and The Wonderful
  4. Why on earth?

Why on earth?

Scheduled Pinned Locked Moved The Weird and The Wonderful
csharpvisual-studiocomhelpquestion
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    leppie
    wrote on last edited by
    #1

    Would someone do this:

    public IEnumerable> GetTaggedSpans(SnapshotSpan span)
    {
    IList> source = new List>(this._trackingTagSpans); // this
    lock (this.mutex)
    {
    source = new List>(this._trackingTagSpans); // and then this, WTF?
    }
    return
    from tagSpan in source
    where span.IntersectsWith(tagSpan.Span.GetSpan(span.Snapshot))
    select tagSpan;
    }

    This is from a builtin class (SimpleTagger<T>) in the Visual Studio SDK. Edit: Looks like I upset a Microsoftie. Instead of downvoting, go fix the f#@kin crap code buddy.

    IronScheme
    ((λ (x) `(,x ',x)) '(λ (x) `(,x ',x)))

    S V 2 Replies Last reply
    0
    • L leppie

      Would someone do this:

      public IEnumerable> GetTaggedSpans(SnapshotSpan span)
      {
      IList> source = new List>(this._trackingTagSpans); // this
      lock (this.mutex)
      {
      source = new List>(this._trackingTagSpans); // and then this, WTF?
      }
      return
      from tagSpan in source
      where span.IntersectsWith(tagSpan.Span.GetSpan(span.Snapshot))
      select tagSpan;
      }

      This is from a builtin class (SimpleTagger<T>) in the Visual Studio SDK. Edit: Looks like I upset a Microsoftie. Instead of downvoting, go fix the f#@kin crap code buddy.

      IronScheme
      ((λ (x) `(,x ',x)) '(λ (x) `(,x ',x)))

      S Offline
      S Offline
      Sentenryu
      wrote on last edited by
      #2

      This guy had his head full of coffee (or other drugs, can't say exactly) Maybe the code where longer before and was shortened to this :doh:

      I'm brazilian and english (well, human languages in general) aren't my best skill, so, sorry by my english. (if you want we can speak in C# or VB.Net =p)

      1 Reply Last reply
      0
      • L leppie

        Would someone do this:

        public IEnumerable> GetTaggedSpans(SnapshotSpan span)
        {
        IList> source = new List>(this._trackingTagSpans); // this
        lock (this.mutex)
        {
        source = new List>(this._trackingTagSpans); // and then this, WTF?
        }
        return
        from tagSpan in source
        where span.IntersectsWith(tagSpan.Span.GetSpan(span.Snapshot))
        select tagSpan;
        }

        This is from a builtin class (SimpleTagger<T>) in the Visual Studio SDK. Edit: Looks like I upset a Microsoftie. Instead of downvoting, go fix the f#@kin crap code buddy.

        IronScheme
        ((λ (x) `(,x ',x)) '(λ (x) `(,x ',x)))

        V Offline
        V Offline
        Vitaly Tomilov
        wrote on last edited by
        #3

        Would a simple error be a ground-breaking concept for you?

        L 1 Reply Last reply
        0
        • V Vitaly Tomilov

          Would a simple error be a ground-breaking concept for you?

          L Offline
          L Offline
          leppie
          wrote on last edited by
          #4

          Vitaly Tomilov wrote:

          Would a simple error be a ground-breaking concept for you?

          What is that suppose to mean? :confused:

          IronScheme
          ((λ (x) `(,x ',x)) '(λ (x) `(,x ',x)))

          V 1 Reply Last reply
          0
          • L leppie

            Vitaly Tomilov wrote:

            Would a simple error be a ground-breaking concept for you?

            What is that suppose to mean? :confused:

            IronScheme
            ((λ (x) `(,x ',x)) '(λ (x) `(,x ',x)))

            V Offline
            V Offline
            Vitaly Tomilov
            wrote on last edited by
            #5

            Looks like a simple error, which needs a simple fix.

            L 1 Reply Last reply
            0
            • V Vitaly Tomilov

              Looks like a simple error, which needs a simple fix.

              L Offline
              L Offline
              leppie
              wrote on last edited by
              #6

              Vitaly Tomilov wrote:

              Looks like a simple error, which needs a simple fix.

              Firstly, simple error yes, but why is this not spotted a mile away? Secondly, this is not my code. It is Microsoft's production code, that lives in VS2010 and VS2012. It is up to them to fix such a simple error.

              IronScheme
              ((λ (x) `(,x ',x)) '(λ (x) `(,x ',x)))

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups