Slashdot is powered by your submissions, so send in your scoop

 



Forgot your password?
typodupeerror
×
Programming Microsoft

Microsoft Roslyn: Reinventing the Compiler As We Know It 195

snydeq writes "Fatal Exception's Neil McAllister sees Microsoft's Project Roslyn potentially reinventing how we view compilers and compiled languages. 'Roslyn is a complete reengineering of Microsoft's .NET compiler toolchain in a new way, such that each phase of the code compilation process is exposed as a service that can be consumed by other applications,' McAllister writes. 'The most obvious advantage of this kind of "deconstructed" compiler is that it allows the entire compile-execute process to be invoked from within .NET applications. With the Roslyn technology, C# may still be a compiled language, but it effectively gains all the flexibility and expressiveness that dynamic languages such as Python and Ruby have to offer.'"
This discussion has been archived. No new comments can be posted.

Microsoft Roslyn: Reinventing the Compiler As We Know It

Comments Filter:
  • by dkleinsc ( 563838 ) on Friday October 21, 2011 @11:44AM (#37793378) Homepage

    If I wanted to, I could rig GCC and the like to do that too: That's the wonderful thing about command-line tools and piping, you can munge things together any way you want. And of course you can always tell gcc to stop partway through the compilation if you need assembler code or a parse tree or something. This sort of thing is common in open-source compilers, because they need these features for debugging purposes and have no reason to leave them out of the released version.

    Of course, I probably don't want to include a feature like this dynamic code execution, because if I screw up, it would be a fantastic way to get a machine to execute code that it's not supposed to.

  • Re:3 years ago (Score:5, Insightful)

    by sourcerror ( 1718066 ) on Friday October 21, 2011 @12:01PM (#37793662)

    Tiny C compiler does this for years:
    http://bellard.org/tcc/ [bellard.org]

    Features

    SMALL! You can compile and execute C code everywhere, for example on rescue disks (about 100KB for x86 TCC executable, including C preprocessor, C compiler, assembler and linker).

    FAST! tcc generates x86 code. No byte code overhead. Compile, assemble and link several times faster than GCC.

    UNLIMITED! Any C dynamic library can be used directly. TCC is heading torward full ISOC99 compliance. TCC can of course compile itself.

    SAFE! tcc includes an optional memory and bound checker. Bound checked code can be mixed freely with standard code.
    Compile and execute C source directly. No linking or assembly necessary. Full C preprocessor and GNU-like assembler included.

    C script supported : just add '#!/usr/local/bin/tcc -run' at the first line of your C source, and execute it directly from the command line.

    With libtcc, you can use TCC as a backend for dynamic code generation.

  • Common Lisp, 1956 (Score:1, Insightful)

    by Anonymous Coward on Friday October 21, 2011 @12:10PM (#37793810)

    If I get a dime for each time someone "reinvents" Common Lisp, I would be rich.

    Please continue innovating, Microsoft. Hint: I think whoever invents the bicycle again, will get to headlines too.

    http://de.wikipedia.org/wiki/Klein_Zaches,_genannt_Zinnober

The moon is made of green cheese. -- John Heywood

Working...