E
emtf
Unregistered / Unconfirmed
GUEST, unregistred user!
用BC3.1设置键盘中断程序,部分源码如下:
...
void far interrupt NewInt9()
{
...
}
...
setvect(9,NewInt9);
...
编译错误提示如下:
Cannot convert 'void (interrupt *)()' to 'void (interrupt far*)(...)'
Type mismatch in parameter '__isr' in call to 'setvect(int,void (interrupt far*)(...))'
问如何对NewInt9()进行强制类型转换,最好能说明原理.
谢谢!
...
void far interrupt NewInt9()
{
...
}
...
setvect(9,NewInt9);
...
编译错误提示如下:
Cannot convert 'void (interrupt *)()' to 'void (interrupt far*)(...)'
Type mismatch in parameter '__isr' in call to 'setvect(int,void (interrupt far*)(...))'
问如何对NewInt9()进行强制类型转换,最好能说明原理.
谢谢!