mirror of
https://github.com/microsoft/regorus.git
synced 2026-08-05 02:16:11 +00:00
Locked down supported values in default rule.
Only scalars, composites and comprehensions containing scalars are supported. This will be changed as OPA fixes bug with default values Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
This commit is contained in:
@@ -61,6 +61,14 @@ impl<'source> Span<'source> {
|
||||
pub fn text(&self) -> &'source str {
|
||||
&self.source.contents[self.start as usize..self.end as usize]
|
||||
}
|
||||
|
||||
pub fn message(&self, kind: &str, msg: &str) -> String {
|
||||
self.source.message(self.line, self.col, kind, msg)
|
||||
}
|
||||
|
||||
pub fn error(&self, msg: &str) -> anyhow::Error {
|
||||
self.source.error(self.line, self.col, msg)
|
||||
}
|
||||
}
|
||||
|
||||
impl<'source> Debug for Span<'source> {
|
||||
|
||||
Reference in New Issue
Block a user