metaborg / spoofax-pie

Spoofax implementation using PIE pipelines
Apache License 2.0
12 stars 9 forks source link

Using an absolute path expression as a custom SDF3 source path results in an exception. #96

Closed molenzwiebel closed 2 years ago

molenzwiebel commented 2 years ago

Summary

See title.

What you did

sdf3 {
  source = files {
    main-source-directory = /src/syntax
  }
}

What you expected to happen

Statix error.

What actually happened

mb.resource.ResourceRuntimeException: Cannot append path '/src/', it is an absolute path
    at mb.spoofax.eclipse.resource.EclipseResourcePath.appendRelativePath(EclipseResourcePath.java:148)
    at mb.spoofax.eclipse.resource.EclipseResourcePath.appendRelativePath(EclipseResourcePath.java:143)

Context

Gohla commented 2 years ago

Fixed by https://github.com/metaborg/spoofax-pie/commit/b4a108e204842bfa428c1cc339953625c8617b60.