Created
October 18, 2010 18:27
-
-
Save bakkdoor/632738 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Compiling lib/argv.fy | |
============= :__script__ ============== | |
Arguments: 0 required, 0 total | |
Locals: 0 | |
Stack size: 5 | |
Lines to IP: 1: 0--1, 13: 0-5, 1: 6-12, 35: 13-18, 15: 19-27 | |
0000: push_rubinius | |
0001: push_literal :"for_option:do:" | |
0003: push_literal #<Rubinius::CompiledMethod for_option:do: file=lib/argv.fy> | |
0005: push_scope | |
0006: push_const_fast :ARGV, 3 | |
0009: send_stack :attach_method, 4 | |
0012: pop | |
0013: push_rubinius | |
0014: push_literal :"for_options:do:" | |
0016: push_literal #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0018: push_scope | |
0019: push_const_fast :ARGV, 7 | |
0022: send_stack :attach_method, 4 | |
0025: pop | |
0026: push_true | |
0027: ret | |
---------------------------------------- | |
========== :"for_option:do:" =========== | |
Arguments: 2 required, 2 total | |
Locals: 2: op_name, block | |
Stack size: 4 | |
Lines to IP: 13: 0--1, 3: 0--1, 2: 0-3, 4: 4-12, 12: 13-14, 13: 15-19 | |
0000: push_literal "Runs a given block if an option is in ARGV." | |
0002: string_dup | |
0003: pop | |
0004: push_const_fast :ARGV, 2 | |
0007: push_local 0 # op_name | |
0009: allow_private | |
0010: send_stack :"index:", 1 | |
0013: create_block #<Rubinius::CompiledMethod for_option:do: file=lib/argv.fy> | |
0015: allow_private | |
0016: send_stack :"if_do:", 1 | |
0019: ret | |
---------------------------------------- | |
========== :"for_option:do:" =========== | |
Arguments: 1 required, 1 total | |
Locals: 1: idx | |
Stack size: 5 | |
Lines to IP: 12: 0-3, 5: 4-15, 9: 16-17, 11: 18-19, 12: 20-24 | |
0000: cast_for_single_block_arg | |
0001: set_local 0 | |
0003: pop | |
0004: push_local_depth 1, 1 | |
0007: allow_private | |
0008: send_stack :":argcount", 0 | |
0011: meta_push_0 | |
0012: allow_private | |
0013: send_stack :":>", 1 | |
0016: create_block #<Rubinius::CompiledMethod for_option:do: file=lib/argv.fy> | |
0018: create_block #<Rubinius::CompiledMethod for_option:do: file=lib/argv.fy> | |
0020: allow_private | |
0021: send_stack :"if_true:else:", 2 | |
0024: ret | |
---------------------------------------- | |
========== :"for_option:do:" =========== | |
Arguments: 1 required, 1 total | |
Locals: 0 | |
Stack size: 4 | |
Lines to IP: 9: 0--1, 6: 0-14, 8: 15-16, 9: 17-21 | |
0000: push_const_fast :ARGV, 1 | |
0003: push_local_depth 1, 0 | |
0006: meta_push_1 | |
0007: allow_private | |
0008: send_stack :":+", 1 | |
0011: allow_private | |
0012: send_stack :":[]", 1 | |
0015: create_block #<Rubinius::CompiledMethod for_option:do: file=lib/argv.fy> | |
0017: allow_private | |
0018: send_stack :"if_do:", 1 | |
0021: ret | |
---------------------------------------- | |
========== :"for_option:do:" =========== | |
Arguments: 1 required, 1 total | |
Locals: 1: arg | |
Stack size: 4 | |
Lines to IP: 8: 0-3, 7: 4-10, 8: 11-15 | |
0000: cast_for_single_block_arg | |
0001: set_local 0 | |
0003: pop | |
0004: push_local_depth 3, 1 | |
0007: push_local 0 | |
0009: make_array 1 | |
0011: allow_private | |
0012: send_stack :"call:", 1 | |
0015: ret | |
---------------------------------------- | |
========== :"for_option:do:" =========== | |
Arguments: 1 required, 1 total | |
Locals: 0 | |
Stack size: 2 | |
Lines to IP: 11: 0--1, 10: 0-2, 11: 3-7 | |
0000: push_local_depth 2, 1 | |
0003: allow_private | |
0004: send_stack :":call", 0 | |
0007: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 2 required, 2 total | |
Locals: 5: op_names, block, done, i, size | |
Stack size: 7 | |
Lines to IP: 35: 0--1, 17: 0--1, 16: 0-3, 19: 4-7, 19: 8-11, 20: 12-13, 21: 14-22, 34: 23-24, 35: 25-29 | |
0000: push_literal "Runs a given block if any of the given options is in ARGV." | |
0002: string_dup | |
0003: pop | |
0004: push_nil | |
0005: set_local 2 # done | |
0007: pop | |
0008: meta_push_0 | |
0009: set_local 3 # i | |
0011: pop | |
0012: push_local 0 # op_names | |
0014: allow_private | |
0015: send_stack :":size", 0 | |
0018: set_local 4 # size | |
0020: pop | |
0021: create_block #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0023: create_block #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0025: allow_private | |
0026: send_stack :"while_true:", 1 | |
0029: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 1 required, 1 total | |
Locals: 0 | |
Stack size: 4 | |
Lines to IP: 21: 0-21 | |
0000: push_local_depth 1, 2 | |
0003: allow_private | |
0004: send_stack :":not", 0 | |
0007: push_local_depth 1, 3 | |
0010: push_local_depth 1, 4 | |
0013: allow_private | |
0014: send_stack :":<", 1 | |
0017: allow_private | |
0018: send_stack :"and:", 1 | |
0021: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 1 required, 1 total | |
Locals: 0 | |
Stack size: 4 | |
Lines to IP: 34: 0--1, 33: 0--1, 22: 0-16, 32: 17-18, 33: 19-23, 33: 24-35 | |
0000: push_const_fast :ARGV, 1 | |
0003: push_local_depth 1, 0 | |
0006: push_local_depth 1, 3 | |
0009: allow_private | |
0010: send_stack :":[]", 1 | |
0013: allow_private | |
0014: send_stack :"index:", 1 | |
0017: create_block #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0019: allow_private | |
0020: send_stack :"if_do:", 1 | |
0023: pop | |
0024: push_local_depth 1, 3 | |
0027: meta_push_1 | |
0028: allow_private | |
0029: send_stack :":+", 1 | |
0032: set_local_depth 1, 3 | |
0035: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 1 required, 1 total | |
Locals: 1: idx | |
Stack size: 5 | |
Lines to IP: 32: 0-3, 23: 4-15, 28: 16-17, 30: 18-19, 31: 20-24, 32: 25-29 | |
0000: cast_for_single_block_arg | |
0001: set_local 0 | |
0003: pop | |
0004: push_local_depth 2, 1 | |
0007: allow_private | |
0008: send_stack :":argcount", 0 | |
0011: meta_push_0 | |
0012: allow_private | |
0013: send_stack :":>", 1 | |
0016: create_block #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0018: create_block #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0020: allow_private | |
0021: send_stack :"if_true:else:", 2 | |
0024: pop | |
0025: push_true | |
0026: set_local_depth 2, 2 | |
0029: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 1 required, 1 total | |
Locals: 0 | |
Stack size: 4 | |
Lines to IP: 28: 0--1, 25: 0--1, 24: 0-13, 25: 14-33, 27: 34-35, 28: 36-40 | |
0000: push_literal "index is: " | |
0002: string_dup | |
0003: push_local_depth 1, 0 | |
0006: allow_private | |
0007: send_stack :":++", 1 | |
0010: allow_private | |
0011: send_stack :":inspect", 0 | |
0014: allow_private | |
0015: send_stack :":println", 0 | |
0018: pop | |
0019: push_const_fast :ARGV, 5 | |
0022: push_local_depth 1, 0 | |
0025: meta_push_1 | |
0026: allow_private | |
0027: send_stack :":+", 1 | |
0030: allow_private | |
0031: send_stack :":[]", 1 | |
0034: create_block #<Rubinius::CompiledMethod for_options:do: file=lib/argv.fy> | |
0036: allow_private | |
0037: send_stack :"if_do:", 1 | |
0040: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 1 required, 1 total | |
Locals: 1: arg | |
Stack size: 4 | |
Lines to IP: 27: 0-3, 26: 4-10, 27: 11-15 | |
0000: cast_for_single_block_arg | |
0001: set_local 0 | |
0003: pop | |
0004: push_local_depth 4, 1 | |
0007: push_local 0 | |
0009: make_array 1 | |
0011: allow_private | |
0012: send_stack :"call:", 1 | |
0015: ret | |
---------------------------------------- | |
========== :"for_options:do:" ========== | |
Arguments: 1 required, 1 total | |
Locals: 0 | |
Stack size: 2 | |
Lines to IP: 30: 0--1, 29: 0-2, 30: 3-7 | |
0000: push_local_depth 3, 1 | |
0003: allow_private | |
0004: send_stack :":call", 0 | |
0007: ret | |
---------------------------------------- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment