Skip to content

#include cant find paths with a starting "/" #215

@tommyisfunny

Description

@tommyisfunny

When including a file with #include which starts with a "/", customasm seems to leave the "/" out when searching for that file.
I came across this when trying to pass a absolute path on Linux as my source file.

for Example:
test.asm:

#include "test2.asm"

LDI 1 23
LDI 3 44 
HLT

then call customasm:
customasm '/home/name/Documents/test.asm'

will give this error:

customasm v0.13.7 (x86_64-unknown-linux-gnu)
assembling `/home/name/Documents/test.asm`...
error: file not found: `home/name/Documents/test2.asm`
 --> /home/name/Documents/test.asm:1:10:
1 | #include "test2.asm" 
  |          ^^^^^^^^^^^  
2 |  
3 | LDI 1 23 

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions