This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
using namespace std;
|
||||
|
||||
namespace Porygon::Binder {
|
||||
enum class BoundExpressionKind : u_int8_t {
|
||||
enum class BoundExpressionKind : uint8_t {
|
||||
Bad,
|
||||
|
||||
LiteralInteger,
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
using namespace std;
|
||||
|
||||
namespace Porygon::Binder {
|
||||
enum class BoundStatementKind : u_int8_t {
|
||||
enum class BoundStatementKind : uint8_t {
|
||||
Bad,
|
||||
Break,
|
||||
Script,
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
#define PORYGONLANG_DIAGNOSTICCODE_HPP
|
||||
|
||||
namespace Porygon::Diagnostics {
|
||||
enum class DiagnosticCode : u_int8_t {
|
||||
enum class DiagnosticCode : uint8_t {
|
||||
// Lex diagnostics
|
||||
UnexpectedCharacter,
|
||||
InvalidStringControlCharacter,
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
namespace Porygon{
|
||||
struct EvaluateResult{
|
||||
const Evaluation::EvalValue* _value;
|
||||
const u_int8_t _result;
|
||||
const uint8_t _result;
|
||||
char * _errorMessage;
|
||||
const size_t _errorSize;
|
||||
public:
|
||||
@@ -38,7 +38,7 @@ namespace Porygon{
|
||||
return _value;
|
||||
}
|
||||
|
||||
[[nodiscard]] u_int8_t GetResult() const{
|
||||
[[nodiscard]] uint8_t GetResult() const{
|
||||
return _result;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#include <iostream>
|
||||
#include <filesystem>
|
||||
#include <fstream>
|
||||
#include <sys/stat.h>
|
||||
#include "ScriptOptions.hpp"
|
||||
#include "Utilities/StringUtils.hpp"
|
||||
#include "Script.hpp"
|
||||
@@ -15,7 +15,8 @@ void Porygon::ScriptOptions::DefaultPrint(const char16_t *s) {
|
||||
}
|
||||
|
||||
bool Porygon::ScriptOptions::DefaultModuleExists(const std::string& moduleName) {
|
||||
return std::filesystem::exists(moduleName);
|
||||
struct stat buffer;
|
||||
return (stat (moduleName.c_str(), &buffer) == 0);
|
||||
}
|
||||
|
||||
Porygon::Script *Porygon::ScriptOptions::DefaultResolveModule(const std::string& moduleName) {
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
#define PORYGONLANG_USERDATASTORAGE_HPP
|
||||
|
||||
#include <unordered_map>
|
||||
#include <mutex>
|
||||
#include "UserData.hpp"
|
||||
#include <mutex>
|
||||
|
||||
namespace Porygon::UserData {
|
||||
class UserDataStorage {
|
||||
|
||||
Reference in New Issue
Block a user