Skip to content

implicit declaration of function 'asm' is invalid in C99 #187

@ishankhare07

Description

@ishankhare07

I get the following error when running the first code example.

#define MILL_USE_PREFIX
#include <stdio.h>
#include <libmill.h>

mill_coroutine void worker(int count, char *text) {
	int i;
	for(i = 0; i != count; i++) {
		printf("%s\n", text);
		mill_msleep(mill_now() + 10);
	}
}

int main() {
	mill_go(worker(4, "a"));
	mill_go(worker(2, "b"));
	mill_go(worker(3, "c"));
	mill_msleep(mill_now() + 100);
	return 0;
}

compiling with
clang -Wall -o main main.c -lmill

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions