You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: version.rb
    path of file: ./repos/kuby-core/lib/kuby/utils/sem_ver
    
    the code of the file until where you have to start completion: module Kuby
  module Utils
    module SemVer
      class Version
        include Comparable

        attr_reader :major, :minor, :patch

        
    
        def self.parse(str, default: 0)
          major, minor, patch = str.split('.')

          new(
            major ? major.to_i : default,
            minor ? minor.to_i : default,
            patch ? patch.to_i : default
          )
        end