Pop-Up Thingie
Sidebar
>>> Magnum BBS <<<
Home
Forum
Files
Dark
Log in
Username
Password
Sidebar
Forum
Usenet
COMP.LANG.C++
#include
From
Mr Flibble
@21:1/5 to
All
on Sat Mar 22 18:04:18 2025
Hi!
Support for the equivalent of #include has been added to "neos" the
universal compiler that can compile any programming language:
class source_package_import : public
semantic_concept<source_package_import>
{
// types
public:
using data_type = neolib::string;
// construction
public:
source_package_import() :
semantic_concept{ "source.package.import", neos::language::emit_type::Infix }
{
}
// emit
public:
bool can_fold() const override
{
return holds_data();
}
bool can_fold(const i_semantic_concept& aRhs) const override
{
return aRhs.name() == "source.package.name";
}
// emit
protected:
void do_fold(i_context& aContext,
neolib::i_ref_ptr<i_semantic_concept>& aResult) override
{
language::source_fragment file{ data<neolib::string>() };
file.set_imported();
aContext.load_fragment(file);
aContext.compiler().compile(std::move(file));
}
void do_fold(i_context& aContext, const i_semantic_concept& aRhs, neolib::i_ref_ptr<i_semantic_concept>& aResult) override
{
data<neolib::string>() = aRhs.data<neolib::i_string>();
aResult.reset(this);
}
};
/Flibble
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)
Who's Online
Recent Visitors
Amstrad Ppc
Sat Oct 31 17:11:55 2026
from
Wiltshire
via
Telnet
Ashenfieldx
Sat Oct 31 16:47:35 2026
from
Guelph, Ontario
via
Telnet
Amstrad Ppc
Sat Oct 31 16:34:27 2026
from
Wiltshire
via
Telnet
Amstrad Ppc
Sat Oct 31 15:21:38 2026
from
Wiltshire
via
Telnet
Amstrad Ppc
Sat Oct 31 15:13:22 2026
from
Wiltshire
via
SSH
Amstrad Ppc
Sat Oct 31 13:42:25 2026
from
Wiltshire
via
SSH
Root Cellar
Sat Oct 31 12:26:17 2026
from
505
via
Telnet
Rixter
Sat Oct 31 11:01:35 2026
from
Madison, Nc
via
Telnet
System Info
Sysop:
Keyop
Location:
Huddersfield, West Yorkshire, UK
Users:
796
Nodes:
16 (
3
/
13
)
Uptime:
149:21:58
Calls:
13,190
Calls today:
13
Files:
15,483
Messages:
6,579,259
Posted today:
2