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. The Lounge
  3. What Language Features Do You Miss In C#?

What Language Features Do You Miss In C#?

Scheduled Pinned Locked Moved The Lounge
csharpjavascriptcomquestiondiscussion
102 Posts 36 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.
  • K Offline
    K Offline
    Kent Sharkey
    wrote on last edited by
    #1

    Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

    -------------- TTFN - Kent

    E A OriginalGriffO M B 26 Replies Last reply
    0
    • K Kent Sharkey

      Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

      -------------- TTFN - Kent

      E Offline
      E Offline
      Ennis Ray Lynch Jr
      wrote on last edited by
      #2

      Universal C style casting of anything and everything. : )

      Need custom software developed? I do custom programming based primarily on MS tools with an emphasis on C# development and consulting. "And they, since they Were not the one dead, turned to their affairs" -- Robert Frost "All users always want Excel" --Ennis Lynch

      1 Reply Last reply
      0
      • K Kent Sharkey

        Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

        -------------- TTFN - Kent

        A Offline
        A Offline
        AspDotNetDev
        wrote on last edited by
        #3

        Inline assembler.

        Thou mewling ill-breeding pignut!

        T 1 Reply Last reply
        0
        • K Kent Sharkey

          Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

          -------------- TTFN - Kent

          OriginalGriffO Offline
          OriginalGriffO Offline
          OriginalGriff
          wrote on last edited by
          #4

          Telepathic interface and direct print to the coffee machine.

          If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.

          "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
          "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

          K E 2 Replies Last reply
          0
          • K Kent Sharkey

            Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

            -------------- TTFN - Kent

            M Offline
            M Offline
            Marc A Brown
            wrote on last edited by
            #5

            I would like to see the addition of a keyword to allow fallthrough in a switch statement (maybe "nobreak"?). I don't need/want to do that often, so the compiler preventing "accidental" fallthrough is nice; however, it sure would be nice to be able to fall through when necessary.

            A M 2 Replies Last reply
            0
            • K Kent Sharkey

              Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

              -------------- TTFN - Kent

              B Offline
              B Offline
              Bassam Abdul Baki
              wrote on last edited by
              #6

              Having a #thread block similar to the #region one except it makes that part of the code threaded and only within a single function. :)

              Web - BM - RSS - Math - LinkedIn

              S 1 Reply Last reply
              0
              • M Marc A Brown

                I would like to see the addition of a keyword to allow fallthrough in a switch statement (maybe "nobreak"?). I don't need/want to do that often, so the compiler preventing "accidental" fallthrough is nice; however, it sure would be nice to be able to fall through when necessary.

                A Offline
                A Offline
                AspDotNetDev
                wrote on last edited by
                #7

                You can use "goto" for a similar result.

                Thou mewling ill-breeding pignut!

                OriginalGriffO M 2 Replies Last reply
                0
                • OriginalGriffO OriginalGriff

                  Telepathic interface and direct print to the coffee machine.

                  If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.

                  K Offline
                  K Offline
                  Kent Sharkey
                  wrote on last edited by
                  #8

                  I can see that linked to the compiler: kick off a long build, coffee gets made. I'm sure someone's built that already though...

                  -------------- TTFN - Kent

                  1 Reply Last reply
                  0
                  • A AspDotNetDev

                    You can use "goto" for a similar result.

                    Thou mewling ill-breeding pignut!

                    OriginalGriffO Offline
                    OriginalGriffO Offline
                    OriginalGriff
                    wrote on last edited by
                    #9

                    ...And get derisive noises at the next code review! :laugh: Or, you could put both operations in methods and call them?

                    If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.

                    "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
                    "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

                    A P 2 Replies Last reply
                    0
                    • OriginalGriffO OriginalGriff

                      ...And get derisive noises at the next code review! :laugh: Or, you could put both operations in methods and call them?

                      If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.

                      A Offline
                      A Offline
                      AspDotNetDev
                      wrote on last edited by
                      #10

                      OriginalGriff wrote:

                      Or, you could put both operations in methods and call them?

                      Not great for all scenarios. FYI, I am talking about "goto case", not "goto label". The former is limited in scope and so isn't plagued by the spaghetti caused by the latter. :)

                      Thou mewling ill-breeding pignut!

                      M OriginalGriffO 2 Replies Last reply
                      0
                      • A AspDotNetDev

                        You can use "goto" for a similar result.

                        Thou mewling ill-breeding pignut!

                        M Offline
                        M Offline
                        Marc A Brown
                        wrote on last edited by
                        #11

                        I could but then my keyboard would jump up and strangle me with the cable. :)

                        1 Reply Last reply
                        0
                        • A AspDotNetDev

                          OriginalGriff wrote:

                          Or, you could put both operations in methods and call them?

                          Not great for all scenarios. FYI, I am talking about "goto case", not "goto label". The former is limited in scope and so isn't plagued by the spaghetti caused by the latter. :)

                          Thou mewling ill-breeding pignut!

                          M Offline
                          M Offline
                          Marc A Brown
                          wrote on last edited by
                          #12

                          Ah, that's what you meant. I hadn't considered such a thing.

                          1 Reply Last reply
                          0
                          • A AspDotNetDev

                            OriginalGriff wrote:

                            Or, you could put both operations in methods and call them?

                            Not great for all scenarios. FYI, I am talking about "goto case", not "goto label". The former is limited in scope and so isn't plagued by the spaghetti caused by the latter. :)

                            Thou mewling ill-breeding pignut!

                            OriginalGriffO Offline
                            OriginalGriffO Offline
                            OriginalGriff
                            wrote on last edited by
                            #13

                            That's not very nice at all: since cases aren't named, they would either have to be anonymous (in which case a maintenance PITA if I insert a case between this and the next) or "goto case myEnum.myValue" which is kinda repellent as well. :laugh:

                            If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.

                            "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
                            "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

                            1 Reply Last reply
                            0
                            • K Kent Sharkey

                              Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

                              -------------- TTFN - Kent

                              L Offline
                              L Offline
                              Lost User
                              wrote on last edited by
                              #14

                              Compile-time templates, C++ style. Generics are great, unless you want to restrict a generic type argument to be "addable" or something like that. Probably not going to happen, given the direction it's taking. Also nice, "break out of named-loop", Java-style.

                              1 Reply Last reply
                              0
                              • K Kent Sharkey

                                Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

                                -------------- TTFN - Kent

                                P Offline
                                P Offline
                                Paulo Zemek
                                wrote on last edited by
                                #15

                                Support to use untyped generics. That is, everytime I have a generic type I also create a non-generic interface so I can use the object without using reflection/dynamic but with a considerable good speed. But it would be great if that was automatic. That is: List<int> only accepts int. I receive it in as a List<> parameter. In this case, all the T parameters, usually seen as int, could be seen as object, doing the casts that are necessary... Well, for the List itself we can already use the IList... but it will be great to have such resource so we could avoid creating interfaces to allow "the more generic, non-generic" call (that is, more generic because it is untyped... I also hate the name generic... it should be typed... a typed list... the ArrayList is the generic one... hehe).

                                K 1 Reply Last reply
                                0
                                • OriginalGriffO OriginalGriff

                                  Telepathic interface and direct print to the coffee machine.

                                  If you get an email telling you that you can catch Swine Flu from tinned pork then just delete it. It's Spam.

                                  E Offline
                                  E Offline
                                  Espen Harlinn
                                  wrote on last edited by
                                  #16

                                  You certainly go straight to The Heart of Everything[^]

                                  Espen Harlinn Principal Architect, Software - Goodtech Projects & Services AS Projects promoting programming in "natural language" are intrinsically doomed to fail. Edsger W.Dijkstra

                                  OriginalGriffO 1 Reply Last reply
                                  0
                                  • P Paulo Zemek

                                    Support to use untyped generics. That is, everytime I have a generic type I also create a non-generic interface so I can use the object without using reflection/dynamic but with a considerable good speed. But it would be great if that was automatic. That is: List<int> only accepts int. I receive it in as a List<> parameter. In this case, all the T parameters, usually seen as int, could be seen as object, doing the casts that are necessary... Well, for the List itself we can already use the IList... but it will be great to have such resource so we could avoid creating interfaces to allow "the more generic, non-generic" call (that is, more generic because it is untyped... I also hate the name generic... it should be typed... a typed list... the ArrayList is the generic one... hehe).

                                    K Offline
                                    K Offline
                                    Kent Sharkey
                                    wrote on last edited by
                                    #17

                                    Hmm. So, for every generic, you also get a Foo (with a better name)? Yeah, I could see how that might be handy for reuse: Bag, Bag etc. shoved into a generic Sort(Bag) method?

                                    -------------- TTFN - Kent

                                    P 1 Reply Last reply
                                    0
                                    • K Kent Sharkey

                                      Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

                                      -------------- TTFN - Kent

                                      S Offline
                                      S Offline
                                      Steve Wellens
                                      wrote on last edited by
                                      #18

                                      sprintf sscanf

                                      Steve Wellens

                                      G S 2 Replies Last reply
                                      0
                                      • K Kent Sharkey

                                        Hmm. So, for every generic, you also get a Foo (with a better name)? Yeah, I could see how that might be handy for reuse: Bag, Bag etc. shoved into a generic Sort(Bag) method?

                                        -------------- TTFN - Kent

                                        P Offline
                                        P Offline
                                        Paulo Zemek
                                        wrote on last edited by
                                        #19

                                        In my case, actually, for every Foo<T> I also have an IFoo where the parameters are as object instead of T. I think java have such feature (I know, in java the implementation is completely different)... I think they use: Foo<?> to say that they don't know the type being used. It is slower than having it rightly typed, but it is faster than having it as dynamic or through reflection.

                                        S 1 Reply Last reply
                                        0
                                        • K Kent Sharkey

                                          Sure, it's on another discussion site[^], but that doesn't mean we can't also discuss it here. Personally, while it certainly doesn't fit in the "missing" category, I see them moving it closer and closer to a hybrid C#/JavaScript language with each new version.

                                          -------------- TTFN - Kent

                                          T Offline
                                          T Offline
                                          thrakazog
                                          wrote on last edited by
                                          #20

                                          My answer is always multiple inheritance. Times that I would use it are rare. But when those times come up man do I ever want that.

                                          Play my game Gravity: IOS[^], Android[^], Windows Phone 7[^]

                                          M A 2 Replies 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