R/00-core-ref-helpers.R

Defines functions is_structural_node

#SO

# identify internal structural nodes (vs user elements)
# Runtime: O(1).
if(FALSE) is_structural_node <- function(x) NULL
is_structural_node(x) %::% . : logical
is_structural_node(x) %as% {
  x %isa% FingerTree || x %isa% Deep || x %isa% Digit || x %isa% Node || x %isa% Single || x %isa% Empty
}

Try the Immutables package in your browser

Any scripts or data that you put into this service are public.

Immutables documentation built on April 29, 2026, 1:06 a.m.