Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

various argument errors attempting to use curses.bi on linux #363

Open
BlameTroi opened this issue May 5, 2022 · 1 comment
Open

various argument errors attempting to use curses.bi on linux #363

BlameTroi opened this issue May 5, 2022 · 1 comment

Comments

@BlameTroi
Copy link

fbc 1.09.0 2022-02-16

I can't see a problem in the definitions for the various mvaddxxx functions and macros in ncurses.bi. decomposing the calls into equivalent move and add functions works. Example:

' attempting to do some quick curses work
#include once "curses.bi"
initscr()
move(0, 0)
addstr("This string gets printed at position (0, 0)")
mvaddstr(1, 0, "and this should be at position (1, 0)")
refresh()
napms(3000)
endwin()

Gets an error when compiled:

Invalid data types in 'mvaddstr(1, 0, "and this should be at position (1, 0)")'

curses.bi and so on are all from the install.

fbc -showincludes curses.bas
curses.bas
| /usr/include/freebasic/curses.bi
| | /usr/include/freebasic/curses/ncurses.bi
| | | /usr/include/freebasic/crt/long.bi
| | | /usr/include/freebasic/crt/stdio.bi
| | | | (/usr/include/freebasic/crt/long.bi)
| | | | /usr/include/freebasic/crt/stddef.bi
| | | | /usr/include/freebasic/crt/stdarg.bi
| | | | /usr/include/freebasic/crt/linux/stdio.bi
| | | (/usr/include/freebasic/crt/stdarg.bi)

I'm stumped.

@rversteegen
Copy link
Member

I've reduced this to a minimal testcase:

iif(0,0,0)

All the mvw* functions expand to an iif.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants