R: Get C length of a vector

get_length {bit} | R Documentation

## Get C length of a vector

### Description

Gets C length of a vector ignoring any length-methods dispatched by classes

### Usage

    get_length(x)

### Arguments

`x` | a vector

### Details

Queries the vector length using C-macro `LENGTH`, this can be substantially faster than `length(unclass(x))`

### Value

integer scalar

### Examples

    length(bit(12))
    get_length(bit(12))

[Package bit version 4.0.4 Index]