Throw NotSupportedException instead of NotImplementedException for unsupported architectures.

This commit is contained in:
jfrijters 2013-01-12 11:35:43 +00:00
Родитель 34e413822f
Коммит 39277c8d3e
1 изменённых файлов: 9 добавлений и 3 удалений

Просмотреть файл

@ -277,8 +277,10 @@ namespace IKVM.Reflection.Writer
return 12;
case IMAGE_FILE_HEADER.IMAGE_FILE_MACHINE_IA64:
return 48;
default:
case IMAGE_FILE_HEADER.IMAGE_FILE_MACHINE_ARM:
return 0;
default:
throw new NotSupportedException();
}
}
}
@ -453,6 +455,10 @@ namespace IKVM.Reflection.Writer
mw.Write((ushort)0x25FF);
mw.Write((uint)peWriter.Headers.OptionalHeader.ImageBase + ImportAddressTableRVA);
}
else
{
throw new NotSupportedException();
}
}
[Conditional("DEBUG")]
@ -527,7 +533,7 @@ namespace IKVM.Reflection.Writer
stubLength = 16;
break;
default:
throw new NotImplementedException();
throw new NotSupportedException();
}
}
@ -658,7 +664,7 @@ namespace IKVM.Reflection.Writer
mw.Write(0); // alignment
break;
default:
throw new NotImplementedException();
throw new NotSupportedException();
}
pos++;
}