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. Create a new programming language?

Create a new programming language?

Scheduled Pinned Locked Moved The Lounge
game-devtutorialquestion
79 Posts 33 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.
  • B Brandon X12000

    Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

    F Offline
    F Offline
    Fabio Franco
    wrote on last edited by
    #65

    Brandon-hbx12000 wrote:

    Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code?

    To really create a language from scratch (no assembly or anything) you'd need to create on a hardware level. Your hardware would have to be your compiler and you should program logical circuits to interpret bits of data, those bits of data could be the character representation of your language. It's a very daunting task and worth only on very specific scenarios, like for chip manufacturers. And it's a good thing our fellow computer engineers of the past have already done that for us.

    "To alcohol! The cause of, and solution to, all of life's problems" - Homer Simpson

    1 Reply Last reply
    0
    • B Brandon X12000

      Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

      M Offline
      M Offline
      Member_5893260
      wrote on last edited by
      #66

      You can do it. Probably the easiest language to write in machine code is FORTH, which (a) is very simple internally, and (b) is mostly written in itself: I think only something like three of its default words are machine code primitives. So if you can get the basic framework of the thing going, (handling the dictionary, getting the environment to work, etc.) and write the machine code words in it ("emit" is one of them, for example) writing the rest of it can be done in your FORTH environment itself. I actually did this at one point, just to see if I could: it turned out to be much easier than I thought it would be.

      B B 2 Replies Last reply
      0
      • B Brandon X12000

        Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

        S Offline
        S Offline
        SeattleC
        wrote on last edited by
        #67

        Sure, invent an entirely new symbol set for arithmetical operators. Choose another logical operator besides if/then for alternation. You can't completely escape looping or recursion, but I'm sure you could express them in a way that has never been seen before. Actually, this was done at least once. See the programming language APL. It's easy to make a programming language general purpose. Just make it as rich as a natural language and then build a compiler that is approximately as smart as a software developer to render it down to efficient machine lnaguage. Such a programming language would be very high level. You'd feed it programs that looked like, "I need an inventory management system." or "Construct a massively mulltiplayer online game that attracts at least 100000 users and generates revenue of $15 million per year." Be aware that since you could also ask the system, "Write a program that solves the Halting Problem" that your compile times may be extremely long. Kinda like working with human developers, it may not get done in a reasonable time.

        1 Reply Last reply
        0
        • B Brandon X12000

          Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

          G Offline
          G Offline
          Gary Huck
          wrote on last edited by
          #68

          The quick, accurate answer is: yes. Chicken & egg. Once upon a time they flipped/toggled switches. Longer answer ... why would you?

          1 Reply Last reply
          0
          • K Kerrash

            Ambiguity of identifiers would be a big concern for me. How would the system know what you meant by a container? Or where a statement started or ended without punctuation?

            K Offline
            K Offline
            KP Lee
            wrote on last edited by
            #69

            Good points. You might be better off making these comments to someone who suggested the "language" instead of someone who agrees with you to begin with. (My comments were much more sarcastic than yours are.)

            1 Reply Last reply
            0
            • S Stefan_Lang

              Member 8331185 wrote:

              for every value in the statement Hello my name is john count the number of spaces

              The problem with such a statement is that a parser would need to distinguish between specific commands and properties such as 'for every', 'count' or 'spaces' and the data that is to be processed, i. e. 'Hello my name is john'. If you made that data part slightly different, such as 'that I do not name here', it would become impossible to resolve. At the very least you must somehow mark the data part. Also you have to be very careful about what constitutes a key phrase that describes the operation. In the above example 'for every' seems an appropriate key phrase, but you could also phrase something like: Every time I press the key down button, move the cursor one line down. Here, 'every time' is a key phrase, making 'every' by itself ambiguous. So when we parse a phrase, we cannot just investigate each word individually, we must also watch for specific phrases of words that subtly changes the meaning. It's doable, but it's incredibly complex. Google for 'Siri' to find an advanced system that might be able to tackle such problems.

              Member 8331185 wrote:

              any idiot can walk up to a PC and provided they can read and write in the English language they should be able to begin programming

              Looking at forums I have some serious doubts about the ability of 'some idiot' to write proper english. Hell, often *I* have trouble understanding what they are saying...

              K Offline
              K Offline
              KP Lee
              wrote on last edited by
              #70

              I've worked with an idiot who's command of the English language was fairly good. His capability to code was non-existant. I groaned every time this person was grouped in the same team I was placed in. That was because my productivity, and every other real programmer's productivity in the team would drop because he was in it. I never understood how year after year, he remained employed. So 8331185's comment is totally unbelievable to me.

              1 Reply Last reply
              0
              • P paul_the_kelly

                HTML isn't a programming language. It isn't Turing complete, and thus can't be used to implement arbitrary algorithms.

                R Offline
                R Offline
                Rob Grainger
                wrote on last edited by
                #71

                True, but definitely a domain-specific language.

                1 Reply Last reply
                0
                • P PIEBALDconsult

                  I was thinking more along the lines of the features added to C# like generics and Linq, or adding OOP to Pascal.

                  R Offline
                  R Offline
                  Rob Grainger
                  wrote on last edited by
                  #72

                  True, but note that languages like Smalltalk and LISP have managed to get along with very few of these extensions - a good minimal set allows easier extension. Consider generics - Smalltalk has no need for such a beast. Even control structures are implemented as messages in Smalltalk, with the pleasant side effect new control structures can be added that feel as natural as the built in ones. Of course, a decent implementation will optimise such constructs to hell and back to get decent performance, as pioneered by Strongtalk and Self.

                  1 Reply Last reply
                  0
                  • N Nagy Vilmos

                    I dig to befer: HTML - specific to the solution - web pages - but not the content. SQL - specific to databases but not to the data stored. Scripts - specific to the OS as a maximum but not the usage. I think you are confusing what the languages do - web, db, scripts - to what they are used for - banking, retail, pron.


                    Panic, Chaos, Destruction. My work here is done. Drink. Get drunk. Fall over - P O'H OK, I will win to day or my name isn't Ethel Crudacre! - DD Ethel Crudacre I cannot live by bread alone. Bacon and ketchup are needed as well. - Trollslayer Have a bit more patience with newbies. Of course some of them act dumb - they're often *students*, for heaven's sake - Terry Pratchett

                    R Offline
                    R Offline
                    Rob Grainger
                    wrote on last edited by
                    #73

                    I befer to dig, HTML - the domain of HTML was the creation of web pages, it was designed for that purpose. SQL - the domain is databases. OK its not a very good domain specific language, but still. Scripts - the domain is the requirement to script administration tasks (in the context I was referring to). In each case, the language is geared to achieving tasks in a particular area (domain). Those domains are not application-level domains, but they are still domains. Futher examples exist - ANT and MSBuild - an XML language designed to automate build scripts. Indeed XML can be viewed as designed for the creation of domain-specific languages. Additionally, many attempts to embed DSL's in existing languages occur - fluent interfaces for example. I'd recommend a perusal of Martin Fowler's new book Domain-Specific Languages for an overview of how important such things are in software architecture.

                    1 Reply Last reply
                    0
                    • C CPallini

                      Windows give more info about your processor (for instance on Windows 7, you may open the Control Panel->System). Anyway Intel processors are AFAIK backward compatible so you may start with a machine code written for an older CPU.

                      If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
                      This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
                      [My articles]

                      B Offline
                      B Offline
                      Brandon X12000
                      wrote on last edited by
                      #74

                      OK so I identified my specific processor name, it's a: Intel(R) Core(TM)2 Quad CPU Q9300 @ 2.50 GHz 2.50 GHz. Edit: Since my OS (operating system) is Windows Vista Ultimate I right-clicked "computer" on the start menu and found it.

                      1 Reply Last reply
                      0
                      • M Member_5893260

                        You can do it. Probably the easiest language to write in machine code is FORTH, which (a) is very simple internally, and (b) is mostly written in itself: I think only something like three of its default words are machine code primitives. So if you can get the basic framework of the thing going, (handling the dictionary, getting the environment to work, etc.) and write the machine code words in it ("emit" is one of them, for example) writing the rest of it can be done in your FORTH environment itself. I actually did this at one point, just to see if I could: it turned out to be much easier than I thought it would be.

                        B Offline
                        B Offline
                        Brandon X12000
                        wrote on last edited by
                        #75

                        Could I lookup a programming language called, "Speedcoding," it was the first language and the first language to be made by machine code it was created by IBM Systems Inc., I'm going to try to see if I can download and find the programming language then study it.

                        1 Reply Last reply
                        0
                        • B Brandon X12000

                          Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

                          B Offline
                          B Offline
                          Brandon X12000
                          wrote on last edited by
                          #76

                          Oh, by the way just to let you'll know if you'll ever wonder, the programming language is gonna be called: U++ (you plus plus), yes I know there is already a an existing programming language with that name out there... Edit: It sounds awesome, Its' full form or full name is gonna be called Universe++ instead of Ultimate so that way Microsoft can't snitch on me :cool:.

                          1 Reply Last reply
                          0
                          • B Brandon X12000

                            Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

                            G Offline
                            G Offline
                            GrantAnderson
                            wrote on last edited by
                            #77

                            Brandon, A true all purposes programming language would be able to define itself. What we use today for high level languages cannot. Essentially we need a new definition/undertanding of programming languages. It needs to be both an object definition language and a procedural language AND allow to automatic storage and automatic communications. Essentially it needs to be a procedural programming language, a data encoding storing definition, and a communication protocol all in one. What we have now does not begin to come close. All the "new" languages today are just warmed over slight variations of the existing paradigm. What this real new language would be would be able to express any programming task or program as wells as be used to describe other things such as human languages... - Grant

                            1 Reply Last reply
                            0
                            • B Brandon X12000

                              Is there a way to create a programming language without using an existing programming language? or to create it from scratch or create it in machine/binary code or assembly code? Also some other questions that are optional that you may answer: - Is there a way for a programming language to be "all-purpose"? (for example this programming language can be used to make games, models, simple applications (like calculators) or anything and EVERYTHING you can imagine) - Is there a way for a programming language to be "self-sustained"? (for example you don't need more than one language like "Lua" to run a massive game like "World of Warcraft" or "Command and Conquer" or any of those games out there or this language does not need support of any kind to run) Any answers will be fully-appreciated. :) Regards, Brandon Proud Member of "The Code Project"

                              B Offline
                              B Offline
                              BrainiacV
                              wrote on last edited by
                              #78

                              FORTH, the one true language! http://www.forth.org/compilers.html[^]

                              Psychosis at 10 Film at 11 Those who do not remember the past, are doomed to repeat it. Those who do not remember the past, cannot build upon it.

                              1 Reply Last reply
                              0
                              • M Member_5893260

                                You can do it. Probably the easiest language to write in machine code is FORTH, which (a) is very simple internally, and (b) is mostly written in itself: I think only something like three of its default words are machine code primitives. So if you can get the basic framework of the thing going, (handling the dictionary, getting the environment to work, etc.) and write the machine code words in it ("emit" is one of them, for example) writing the rest of it can be done in your FORTH environment itself. I actually did this at one point, just to see if I could: it turned out to be much easier than I thought it would be.

                                B Offline
                                B Offline
                                BrainiacV
                                wrote on last edited by
                                #79

                                YES! (see post later) FORTH is the way to go! Small, fast, and infinitely abrigeable.

                                Psychosis at 10 Film at 11 Those who do not remember the past, are doomed to repeat it. Those who do not remember the past, cannot build upon it.

                                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