Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

algo-lang

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

algo-lang - npm Package Compare versions

Comparing version 1.0.13 to 1.0.14

4

build/ast/algorithm.js

@@ -49,3 +49,3 @@ 'use strict';

this.getOverVariables(paramsDecls, (variables, name, index) => {
if (variables.type !== args[index].resType) throw new _error.JungleError('L\'argument ' + (index + 1) + ' de la routine routine ' + this.name + ' attend un ' + variables.type.name + ' mais un ' + args[index].resType.name + ' a été fourni à la place', args[index].location);
if (!variables.type.isCompatibleWith(args[index].resType)) throw new _error.JungleError('L\'argument ' + (index + 1) + ' de la routine routine ' + this.name + ' attend un ' + variables.type.name + ' mais un ' + args[index].resType.name + ' a été fourni à la place', args[index].location);

@@ -67,2 +67,4 @@ if (variables.assignable && !args[index].writable) throw new _error.JungleError('L\'argument ' + (index + 1) + ' de la routine ' + this.name + ' attend une expression ' + 'assignable pour un paramètre global', args[index].location);

if (this.type && !this.returnValue) throw new _error.JungleError('retourne n\'a pas été appelé durant l\'exécution de la routine ' + this.name);
const res = this.returnValue;

@@ -69,0 +71,0 @@ this.returnValue = null;

@@ -19,3 +19,7 @@ 'use strict';

}
isCompatibleWith(type) {
return this === type || type.name === '!nul';
}
}
exports.Pointer = Pointer;

@@ -33,3 +33,7 @@ 'use strict';

}
isCompatibleWith(type) {
return this === type;
}
}
exports.Type = Type;

@@ -86,3 +86,3 @@ 'use strict';

this.registerRule('*/', this.lex_62, 'comment');
this.registerRule(new RegExp('.'), this.lex_63, 'comment');
this.registerRule(new RegExp('.|\\n'), this.lex_63, 'comment');
this.registerRule('\\n', this.lex_64, 'dbstring');

@@ -89,0 +89,0 @@ this.registerRule(new RegExp('\\\\([\\\\"])'), this.lex_65, 'dbstring');

@@ -46,3 +46,3 @@ import {Ast} from './base.js'

this.getOverVariables(paramsDecls, (variables, name, index) => {
if (variables.type !== args[index].resType)
if (!variables.type.isCompatibleWith(args[index].resType))
throw new JungleError('L\'argument ' + (index + 1) + ' de la routine routine ' + this.name + ' attend un ' +

@@ -72,2 +72,5 @@ variables.type.name + ' mais un ' + args[index].resType.name + ' a été fourni à la place', args[index].location)

if (this.type && !this.returnValue)
throw new JungleError('retourne n\'a pas été appelé durant l\'exécution de la routine ' + this.name)
const res = this.returnValue

@@ -74,0 +77,0 @@ this.returnValue = null

@@ -12,2 +12,6 @@ import {Type} from './type.js'

}
isCompatibleWith(type) {
return this === type || type.name === '!nul'
}
}

@@ -26,2 +26,6 @@ import {Ast} from './base.js'

}
isCompatibleWith(type) {
return this === type
}
}

@@ -73,3 +73,3 @@ import * as ast from "./ast"

this.registerRule('*/', this.lex_62, 'comment')
this.registerRule(new RegExp('.'), this.lex_63, 'comment')
this.registerRule(new RegExp('.|\\n'), this.lex_63, 'comment')
this.registerRule('\\n', this.lex_64, 'dbstring')

@@ -76,0 +76,0 @@ this.registerRule(new RegExp('\\\\([\\\\"])'), this.lex_65, 'dbstring')

{
"name": "algo-lang",
"version": "1.0.13",
"version": "1.0.14",
"description": "Algorithmic language interpreter (in French only for now)",

@@ -5,0 +5,0 @@ "homepage": "https://bitbucket.org/lsystems/algo-lang/overview",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc