www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Easy way to implement custom runtime?

reply "Kaylan" <kbzombie gmail.com> writes:
Does anyone know of an easy way to figure out how a runtime 
feature should be implemented from reference errors emited at 
compile time? I seem to be doing really well with compiling 
runtime free applications but when i need to implement a runtime 
feature theres not much info to work with. Like whats the 
compiler expecting? Function, class, pointer to something???? I 
could use the default runtime source for reference but how do i 
know what to look for?

There should be a section in the library reference about the 
compiler referencing system. In my opinion that would boost the 
useability of D in general by a LOT.

Any and all thoughts are welcome, thanks.
Jan 05 2013
parent Jacob Carlborg <doob me.com> writes:
On 2013-01-05 13:01, Kaylan wrote:
 Does anyone know of an easy way to figure out how a runtime feature
 should be implemented from reference errors emited at compile time? I
 seem to be doing really well with compiling runtime free applications
 but when i need to implement a runtime feature theres not much info to
 work with. Like whats the compiler expecting? Function, class, pointer
 to something???? I could use the default runtime source for reference
 but how do i know what to look for?

 There should be a section in the library reference about the compiler
 referencing system. In my opinion that would boost the useability of D
 in general by a LOT.

 Any and all thoughts are welcome, thanks.

It's not a good way but you can remove the runtime and compile some code. If it uses a given part of the runtime it will result in a linker error. Then look up the missing function in the druntime source and see what it should be. -- /Jacob Carlborg
Jan 05 2013