summaryrefslogtreecommitdiff
path: root/masm/main.c
diff options
context:
space:
mode:
authorFreya Murphy <freya@freyacat.org>2024-09-11 12:06:09 -0400
committerFreya Murphy <freya@freyacat.org>2024-09-11 12:06:09 -0400
commite3d2e31377030e84066bed4bbc04bf6c56206305 (patch)
treed5e7428212606a0f64d5b2e628b3f507948b8e2f /masm/main.c
parentjoe (diff)
downloadmips-e3d2e31377030e84066bed4bbc04bf6c56206305.tar.gz
mips-e3d2e31377030e84066bed4bbc04bf6c56206305.tar.bz2
mips-e3d2e31377030e84066bed4bbc04bf6c56206305.zip
refactor
Diffstat (limited to '')
-rw-r--r--masm/main.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/masm/main.c b/masm/main.c
index be156d8..760e4fa 100644
--- a/masm/main.c
+++ b/masm/main.c
@@ -3,27 +3,24 @@
#include <string.h>
#include "asm.h"
-#include "mips.h"
void help(void) {
printf("usage: masm [options] source.asm\n\n");
printf("options:\n");
printf("\t-h\t\tprints this help message\n");
- printf("\t-i isa\t\tselect a ISA to assemble to (mips32)\n");
printf("\t-o output\tselect a output file destination\n");
}
int main(int argc, char **argv) {
struct assembler_arguments args = {
- .isa = ISA_MIPS32,
.in_file = NULL,
.out_file = NULL,
};
int c;
- while ((c = getopt(argc, argv, "ho:i:")) != 1) {
+ while ((c = getopt(argc, argv, "ho:")) != 1) {
switch(c) {
case 'h':
help();
@@ -31,14 +28,6 @@ int main(int argc, char **argv) {
case 'o':
args.out_file = optarg;
break;
- case 'i':
- if (strcmp(optarg, "mips32") == 0) {
- args.isa = ISA_MIPS32;
- } else {
- ERROR("invalid isa '%s'", optarg);
- return M_ERROR;
- }
- break;
case '?':
return M_ERROR;
default: