Rework for git.tesses.org, GC* is std::shared_ptr maybe will fix crash during exit
Some checks failed
Build and Deploy on Tag / update-tap (push) Has been cancelled
Build and Deploy on Tag / build-arch (push) Has been cancelled

This commit is contained in:
2026-04-30 16:00:00 -05:00
parent fca18e63a6
commit 991f2a217d
78 changed files with 1243 additions and 849 deletions

View File

@@ -15,7 +15,8 @@ static bool Download(Tesses::Framework::Filesystem::VFSPath filename,std::shared
if(inContainer && (*inContainer=="1" || *inContainer=="y" || *inContainer=="Y"))
{
HttpRequest req;
req.url = "https://downloads.tesses.net/ShellPackage.crvm";
req.followRedirects=true;
req.url = "https://redirect.tesses.net/crosslang-shell";
req.method = "GET";
HttpResponse resp(req);
if(resp.statusCode == StatusCode::OK)
@@ -34,13 +35,14 @@ static bool Download(Tesses::Framework::Filesystem::VFSPath filename,std::shared
while(true)
{
std::cout << "File " << filename.ToString() << " not found, do you want to download the installer from: https://downloads.tesses.net/ShellPackage.crvm (this may install other stuff as well) (Y/n)? ";
std::cout << "File " << filename.ToString() << " not found, do you want to download the installer from: https://redirect.tesses.net/crosslang-shell (this may install other stuff as well) (Y/n)? ";
std::string line;
std::getline(std::cin,line);
if(line == "Y" || line == "y")
{
HttpRequest req;
req.url = "https://downloads.tesses.net/ShellPackage.crvm";
req.followRedirects = true;
req.url = "https://redirect.tesses.net/crosslang-shell";
req.method = "GET";
HttpResponse resp(req);
if(resp.statusCode == StatusCode::OK)
@@ -89,7 +91,8 @@ TObject CrossLangShell(GCList& ls, std::vector<std::string>& argv)
auto subdir = std::make_shared<Tesses::Framework::Filesystem::SubdirFilesystem>(Tesses::Framework::Filesystem::LocalFS,dir);
HttpRequest req;
req.url = "https://downloads.tesses.net/ShellPackage.crvm";
req.followRedirects=true;
req.url = "https://redirect.tesses.net/crosslang-shell";
req.method = "GET";
HttpResponse resp(req);
if(resp.statusCode == StatusCode::OK)

View File

@@ -212,15 +212,15 @@ void CrossLangCompiler(std::vector<std::string>& argv)
}
GC* gc=nullptr;
GCList* ls=nullptr;
std::shared_ptr<GC> gc;
std::shared_ptr<GCList> ls;
TRootEnvironment* env=nullptr;
if(comptime != "none")
{
gc = new GC();
std::shared_ptr<GC> gc= std::make_shared<GC>();
gc->Start();
ls = new GCList(gc);
env = TRootEnvironment::Create(ls,TDictionary::Create(ls));
ls = std::make_shared<GCList>(gc);
env = TRootEnvironment::Create(*ls,TDictionary::Create(*ls));
if(comptime == "secure")
{
@@ -281,10 +281,5 @@ void CrossLangCompiler(std::vector<std::string>& argv)
gen.Save(strm);
}
if(gc != nullptr)
{
delete ls;
delete gc;
}
}
}

View File

@@ -9,7 +9,7 @@ using namespace Tesses::Framework::Filesystem;
namespace Tesses::CrossLang::Programs {
TObject CrossLangInterperter(GCList& ls,TRootEnvironment* env,std::vector<std::string>& argv)
{
GC* gc = ls.GetGC();
std::shared_ptr<GC> gc = ls.GetGC();
if(argv.size() > 1)
{
std::ifstream strm(argv[1],std::ios_base::in|std::ios_base::binary);