Fixed not found calculation warnings showing [object Object]
They were using the wrong "toString" method
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import constant from './constant.js';
|
||||
import { toString } from '../resolve.js';
|
||||
|
||||
const accessor = {
|
||||
create({name, path}) {
|
||||
@@ -53,7 +54,7 @@ const accessor = {
|
||||
reduce(node, scope, context){
|
||||
let { result } = accessor.compile(node, scope, context);
|
||||
if (result.parseType === 'accessor'){
|
||||
context.error(`${accessor.toString(result)} not found, set to 0`);
|
||||
context.error(`${toString(result)} not found, set to 0`);
|
||||
return {
|
||||
result: constant.create({
|
||||
value: 0,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import resolve from '../resolve.js';
|
||||
import resolve, { toString } from '../resolve.js';
|
||||
import constant from './constant.js';
|
||||
|
||||
const symbol = {
|
||||
@@ -46,7 +46,7 @@ const symbol = {
|
||||
if (result.parseType === 'symbol'){
|
||||
context.error({
|
||||
type: 'info',
|
||||
message: `${result.toString()} not found, set to 0`
|
||||
message: `${toString(result)} not found, set to 0`
|
||||
});
|
||||
return {
|
||||
result: constant.create({value: 0}),
|
||||
|
||||
Reference in New Issue
Block a user