mirror of
				https://github.com/LadybirdBrowser/ladybird.git
				synced 2025-10-31 13:20:59 +00:00 
			
		
		
		
	LibGC+Everywhere: Factor out a LibGC from LibJS
Resulting in a massive rename across almost everywhere! Alongside the namespace change, we now have the following names: * JS::NonnullGCPtr -> GC::Ref * JS::GCPtr -> GC::Ptr * JS::HeapFunction -> GC::Function * JS::CellImpl -> GC::Cell * JS::Handle -> GC::Root
This commit is contained in:
		
							parent
							
								
									ce23efc5f6
								
							
						
					
					
						commit
						f87041bf3a
					
				
				
				Notes:
				
					github-actions[bot]
				
				2024-11-15 13:50:17 +00:00 
				
			
			Author: https://github.com/shannonbooth
Commit: f87041bf3a
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2345
			
					 1722 changed files with 9939 additions and 9906 deletions
				
			
		|  | @ -5,7 +5,7 @@ | |||
|  * SPDX-License-Identifier: BSD-2-Clause | ||||
|  */ | ||||
| 
 | ||||
| #include <LibJS/Heap/Heap.h> | ||||
| #include <LibGC/Heap.h> | ||||
| #include <LibWeb/Bindings/Intrinsics.h> | ||||
| #include <LibWeb/Bindings/WorkerNavigatorPrototype.h> | ||||
| #include <LibWeb/HTML/WorkerGlobalScope.h> | ||||
|  | @ -13,9 +13,9 @@ | |||
| 
 | ||||
| namespace Web::HTML { | ||||
| 
 | ||||
| JS_DEFINE_ALLOCATOR(WorkerNavigator); | ||||
| GC_DEFINE_ALLOCATOR(WorkerNavigator); | ||||
| 
 | ||||
| JS::NonnullGCPtr<WorkerNavigator> WorkerNavigator::create(WorkerGlobalScope& global_scope) | ||||
| GC::Ref<WorkerNavigator> WorkerNavigator::create(WorkerGlobalScope& global_scope) | ||||
| { | ||||
|     return global_scope.realm().create<WorkerNavigator>(global_scope); | ||||
| } | ||||
|  | @ -40,14 +40,14 @@ void WorkerNavigator::visit_edges(Cell::Visitor& visitor) | |||
|     visitor.visit(m_service_worker_container); | ||||
| } | ||||
| 
 | ||||
| JS::NonnullGCPtr<MediaCapabilitiesAPI::MediaCapabilities> WorkerNavigator::media_capabilities() | ||||
| GC::Ref<MediaCapabilitiesAPI::MediaCapabilities> WorkerNavigator::media_capabilities() | ||||
| { | ||||
|     if (!m_media_capabilities) | ||||
|         m_media_capabilities = realm().create<MediaCapabilitiesAPI::MediaCapabilities>(realm()); | ||||
|     return *m_media_capabilities; | ||||
| } | ||||
| 
 | ||||
| JS::NonnullGCPtr<ServiceWorkerContainer> WorkerNavigator::service_worker() | ||||
| GC::Ref<ServiceWorkerContainer> WorkerNavigator::service_worker() | ||||
| { | ||||
|     if (!m_service_worker_container) | ||||
|         m_service_worker_container = realm().create<ServiceWorkerContainer>(realm()); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Shannon Booth
						Shannon Booth