Skip to content

Commit

Permalink
add copyrights to files
Browse files Browse the repository at this point in the history
  • Loading branch information
Rexicon226 committed Jun 22, 2024
1 parent e168158 commit 849ae9f
Show file tree
Hide file tree
Showing 21 changed files with 86 additions and 3 deletions.
4 changes: 4 additions & 0 deletions build.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

const std = @import("std");
const CpythonStep = @import("build/CpythonStep.zig");

Expand Down
8 changes: 7 additions & 1 deletion build.zig.zon
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
.{
.name = "osmium",
.version = "0.1.0",
.paths = .{""},
.minimum_zig_version = "0.13.0",
.paths = .{
"src",
"build.zig",
"build.zig.zon",
"README.md",
},
.dependencies = .{
.tracer = .{
.url = "https://github.com/Rexicon226/zig-tracer/archive/6400e066bb3849be4906f3b6e124d6c8c5a5083f.tar.gz",
Expand Down
4 changes: 4 additions & 0 deletions graph/plot.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright (c) 2024, David Rubin <[email protected]>
#
# SPDX-License-Identifier: GPL-3.0-only

import struct
import matplotlib.pyplot as plt
import networkx as nx
Expand Down
4 changes: 4 additions & 0 deletions src/compiler/CodeObject.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! A 3.10 CodeObject

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/compiler/Instruction.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! A thin wrapper around the 2 bytes that makeup the bytecode

const Instruction = @This();
Expand Down
4 changes: 4 additions & 0 deletions src/compiler/Marshal.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Serialization of PYC files.

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/compiler/objtype.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

/// Object types
pub const ObjType = enum(u8) {
TYPE_NULL = '0',
Expand Down
5 changes: 3 additions & 2 deletions src/compiler/opcodes.zig
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// This file was autogenerated by tools/opcode2zig.zig
// DO NOT EDIT
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

/// Op Codes
pub const OpCode = enum(u8) {
Expand Down
4 changes: 4 additions & 0 deletions src/crash_report.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Overrides the panics to provide more information
//! Slightly stolen from the Zig Compiler :P

Expand Down
4 changes: 4 additions & 0 deletions src/frontend/Python.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Inputs python source and outputs Bytecode

pub const Error = error{
Expand Down
4 changes: 4 additions & 0 deletions src/frontend/cpython.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! CPython bindings for compiling source code into bytecode.

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/graph/Graph.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Creates a temporal graph of a CodeObject

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/main.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

const std = @import("std");
const builtin = @import("builtin");

Expand Down
4 changes: 4 additions & 0 deletions src/modules/builtins.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Scope References to builtin functions
// NOTE: Builtin functions are expected to append their returns to the stack themselves.

Expand Down
4 changes: 4 additions & 0 deletions src/print_co.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Logic to print a CodeObject in a tasteful manner.

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/vm/Object.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

const Object = @This();

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/vm/Vm.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Virtual Machine that runs Python Bytecode blazingly fast

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions src/vm/errors.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Handles error creation, serialisation, and printing

const std = @import("std");
Expand Down
4 changes: 4 additions & 0 deletions tests/cases.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

const std = @import("std");
const matrix = @import("matrix.zig");

Expand Down
4 changes: 4 additions & 0 deletions tests/matrix.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

const std = @import("std");
const File = std.fs.File;
const Allocator = std.mem.Allocator;
Expand Down
4 changes: 4 additions & 0 deletions tools/opcode2zig.zig
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Copyright (c) 2024, David Rubin <[email protected]>
//
// SPDX-License-Identifier: GPL-3.0-only

//! Converts "opcode.h" into a zig enum.

const std = @import("std");
Expand Down

0 comments on commit 849ae9f

Please sign in to comment.