Closed
Description
The structure of the ABNF documented in Appendix IV of SPDX 2.1 makes it impossible to recover from an expression like (MIT OR BSD)
using a tool like spdx-correct. Would it be reasonable to assume that all license-id
tokens are a subset of all valid id-string
tokens so we could apply validation optionally at the parse phase instead of the lex phase?
That is, could we do something like this:
var parse = require('spdx-expression-parse');
var assert = require('assert');
assert.deepEqual(
parse('(MIT OR BSD)', { relax: true }),
{
left: { license: 'MIT' },
conjunction: 'or',
right: { license: 'BSD' }
}
);
Metadata
Metadata
Assignees
Labels
No labels