Skip to main content
added 175 characters in body
Source Link
thorsten müller
  • 12.1k
  • 4
  • 51
  • 54

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library isare written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

So you have different parts of a language that can or have to be written in other languages. Nothing would keep you from writing the interpreter in C and the libraries in C++ (though maybe making a few things more difficult). You could even have multiple steps and use a language that is very good at text processing to generate some intermediate data which then is processed by some C code.

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly another. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library is written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

So you have different parts of a language that can or have to be written in other languages. Nothing would keep you from writing the interpreter in C and the libraries in C++ (though maybe making a few things more difficult).

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library are written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

So you have different parts of a language that can or have to be written in other languages. Nothing would keep you from writing the interpreter in C and the libraries in C++ (though maybe making a few things more difficult). You could even have multiple steps and use a language that is very good at text processing to generate some intermediate data which then is processed by some C code.

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly another. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.

added 229 characters in body
Source Link
thorsten müller
  • 12.1k
  • 4
  • 51
  • 54

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library is written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

So you have different parts of a language that can or have to be written in other languages. Nothing would keep you from writing the interpreter in C and the libraries in C++ (though maybe making a few things more difficult).

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library is written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library is written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

So you have different parts of a language that can or have to be written in other languages. Nothing would keep you from writing the interpreter in C and the libraries in C++ (though maybe making a few things more difficult).

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.

Source Link
thorsten müller
  • 12.1k
  • 4
  • 51
  • 54

You are basically right. If it is said that Ruby is written in C, this means that the language interpreter and parts of the core library is written in C.

So the Ruby interpreter is a C program that takes a text file as input, processes it and then calls functions that are either in another text file (if written in Ruby) or that are compiled C code, as much of the basic functionality that needs to directly access system resources like memory, the file system and more. And some functions that require very high performance.

Factors for the decision may be just the same as for other complex applications. Performance is one. The ability to write code that can access system resources directly. So in most cases it has to be a compiled language (though in theory you could write a Ruby interpreter in Python). Availability on different systems is important if you want your language to run on Linux, Win, OS X and others.