Skip to content

Commit

Permalink
Correct licence and comments
Browse files Browse the repository at this point in the history
  • Loading branch information
hiperiondev committed May 13, 2024
1 parent b11bfb6 commit c2fe2b0
Show file tree
Hide file tree
Showing 22 changed files with 32 additions and 34 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2024 Hiperión
Copyright (c) 2024 Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_assembler.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_assembler.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_assembler_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_assembler_utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_disassembler.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_disassembler.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_opcodes_def.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion assembler_disassembler/vm_opcodes_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion examples/example.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion temp/ffi_fiber.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion temp/ffi_fiber.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion test/termcolors.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion test/test.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
13 changes: 3 additions & 10 deletions vm/vm.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down Expand Up @@ -73,15 +73,7 @@ static inline bool vm_are_values_equal(vm_thread_t **thread, vm_value_t a, vm_va
return result;
}

// stack
void vm_push(vm_thread_t **thread, vm_value_t value) {
STK_OBJ(thread, (*thread)->sp++)= value;
}

vm_value_t vm_pop(vm_thread_t **thread) {
return STK_OBJ(thread, --(*thread)->sp);
}

/*
vm_errors_t vm_drop_n(vm_thread_t **thread, uint32_t qty) {
if (qty < 1 || qty - 1 > (*thread)->sp) {
return VM_ERR_BAD_VALUE;
Expand All @@ -96,6 +88,7 @@ vm_errors_t vm_drop_n(vm_thread_t **thread, uint32_t qty) {
return VM_ERR_OK;
}
*/

void vm_push_frame(vm_thread_t **thread, uint8_t locals) {
(*thread)->frames[(*thread)->fc].pc = (*thread)->pc;
Expand Down
13 changes: 9 additions & 4 deletions vm/vm.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down Expand Up @@ -448,7 +448,9 @@ void vm_destroy_thread(vm_thread_t **thread);
* @param thread Thread
* @param value Value
*/
void vm_push(vm_thread_t **thread, vm_value_t value);
inline void vm_push(vm_thread_t **thread, vm_value_t value) {
STK_OBJ(thread, (*thread)->sp++) = value;
}

/**
* @fn vm_value_t vm_pop(vm_thread_t **thread)
Expand All @@ -457,16 +459,19 @@ void vm_push(vm_thread_t **thread, vm_value_t value);
* @param thread Thread
* @return Value Value
*/
vm_value_t vm_pop(vm_thread_t **thread);
inline vm_value_t vm_pop(vm_thread_t **thread) {
return STK_OBJ(thread, --(*thread)->sp);
}

/**
* @fn vm_errors_t vm_drop_n(vm_thread_t **thread, uint32_t qty)
* @brief Drop elements n elements from stack
*
* @param thread Thread
* @param qty Quantity
*/
vm_errors_t vm_drop_n(vm_thread_t **thread, uint32_t qty);
*/

/**
* @fn void vm_push_frame(vm_thread_t **thread, uint8_t nargs)
Expand Down
2 changes: 1 addition & 1 deletion vm/vm_heap.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion vm/vm_opcodes.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion vm_ffis/ffi_print.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion vm_ffis/ffi_print.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @date 2024
* @copyright MIT License
* @see https://github.com/hiperiondev/stack_vm
Expand Down
2 changes: 1 addition & 1 deletion vm_libraries/vm_libstring.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @version 2.0
* @date 2024
* @copyright MIT License
Expand Down
2 changes: 1 addition & 1 deletion vm_libraries/vm_libstring.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*
* please contact their authors for more information.
*
* @author Emiliano Gonzalez (egonzalez . hiperion @ gmail . com))
* @author Emiliano Augusto Gonzalez (egonzalez . hiperion @ gmail . com)
* @version 2.0
* @date 2024
* @copyright MIT License
Expand Down

0 comments on commit c2fe2b0

Please sign in to comment.