-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
compilerAnything about the compilerAnything about the compilerdebugAnything about debuggingAnything about debuggingenhancementNew feature or requestNew feature or request
Description
Let's imagine a scenario:
File library1.corth:
include "linux_x86/stdio.corth"
proc hello-world -> in
"Hello, world!\n" puts
end
File library2.corth:
include "library1.corth"
File main.corth:
include "library2.corth"
proc main int int -> int in
hello-world
end 0 end
In this program, main.corth is trying to call the hello-world
procedure which is inside library1.corth. Compiler allows this behavior because library2.corth includes library1.corth. C/C++ compiler also allows this. However this is an unwanted "feature", because in Corth, every source file should include the source files that it needs and only the source files that it needs. So the compiler should to complain, or at least create a warning about this situation.
Metadata
Metadata
Assignees
Labels
compilerAnything about the compilerAnything about the compilerdebugAnything about debuggingAnything about debuggingenhancementNew feature or requestNew feature or request